package com.ly.heart.domain;

import java.util.Date;
import java.util.List;

import com.baomidou.mybatisplus.annotation.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.Data;
import lombok.experimental.Accessors;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ly.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

/**
 * 金蝶-询价/报价单对象 erp_king_inquiry_info
 *
 * @author cxl
 * @date 2024-07-11
 */
@TableName ("erp_king_inquiry_info")
@ApiModel (value = "金蝶-询价/报价单", description = "金蝶-询价/报价单")
@Data
@Accessors(chain = true)
public class KingInquiryEntity {

        /** 主键id */
        @TableId (type = IdType.INPUT)
        private String id;

        /** 类型(0询价单 1报价单) */
        @ApiModelProperty ("类型(0询价单 1报价单)")
        @TableField ("type")
        @Excel (name = "类型(0询价单 1报价单)")
        private String type;

        /** 单据类型（单据类型接口 */
        @TableField ("doc_type")
        @ApiModelProperty ("单据类型（单据类型接口)")
        private String docType;

        /** 业务类型（与单据类型相对应） */
        @TableField ("doc_business_type")
        @ApiModelProperty ("业务类型（与单据类型相对应）")
        private String docBusinessType;

        /** 单据编号 */
        @ApiModelProperty ("单据编号")
        @TableField ("doc_code")
        @Excel (name = "单据编号")
        private String docCode;

        /** 询价/报价日期 */
        @ApiModelProperty ("询价/报价日期")
        @TableField ("ask_time")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "询价/报价日期", width = 30, dateFormat = "yyyy-MM-dd")
        private Date askTime;

        /** 询价单号（报价单才有） */
        @TableField ("ask_code")
        @ApiModelProperty ("询价单号（报价单才有）")
        @Excel (name = "询价单号", readConverterExp = "报=价单才有")
        private String askCode;

        /** 比价模式（字典配置：物料比价/总金额比价） */
        @TableField ("compare_mode")
        @ApiModelProperty ("比价模式（字典配置：物料比价/总金额比价）")
        private String compareMode;

        /** 采购组织（默认当前子公司） */
        @TableField ("purchase_org")
        @ApiModelProperty ("采购组织（默认当前子公司）")
        @Excel (name = "采购组织")
        private String purchaseOrg;

        /** 采购部门（当前人员子公司） */
        @TableField ("purchase_dept")
        @ApiModelProperty ("采购部门（当前人员子公司）")
        private String purchaseDept;

        /** 采购组(采购组接口) */
        @ApiModelProperty ("采购组(采购组接口)")
        @TableField ("purchase_group")
        @Excel (name = "采购组(采购组接口)")
        private String purchaseGroup;

        /** 采购员工 */
        @ApiModelProperty ("采购员工")
        @TableField ("purchase_by")
        @Excel (name = "采购员工")
        private String purchaseBy;

        /** 是否适用所有供应商 */
        @ApiModelProperty ("是否适用所有供应商")
        @TableField ("is_all")
        @Excel (name = "是否适用所有供应商")
        private Boolean isAll;

        /** 报价截止日期 */
        @ApiModelProperty ("报价截止日期")
        @TableField ("quotation_deadline")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "报价截止日期", width = 30, dateFormat = "yyyy-MM-dd")
        private Date quotationDeadline;

        /** 价格生效日期 */
        @ApiModelProperty ("价格生效日期")
        @TableField ("price_effective_date")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "价格生效日期", width = 30, dateFormat = "yyyy-MM-dd")
         private Date priceEffectiveDate;

        /** 价格失效日期 */
        @ApiModelProperty ("价格失效日期")
        @TableField ("price_expiration_date")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "价格失效日期", width = 30, dateFormat = "yyyy-MM-dd")
        private Date priceExpirationDate;

        /** 单据状态 */
        @ApiModelProperty ("单据状态")
        @TableField ("doc_status")
        @Excel (name = "单据状态")
        private String docStatus;

        /** 允许比价时采纳多个供应商 */
        @ApiModelProperty ("允许比价时采纳多个供应商")
        @TableField ("is_allow_adopting_suppliers")
        @Excel (name = "允许比价时采纳多个供应商")
        private Boolean isAllowAdoptingSuppliers;

        /** 供应商code(报价单才有) */
        @ApiModelProperty ("供应商code(报价单才有)")
        @TableField ("supplier_code")
        @Excel (name = "供应商code(报价单才有)")
        private String supplierCode;

        /** 联系人(报价单才有) */
        @ApiModelProperty ("联系人(报价单才有)")
        @TableField ("contracts")
        @Excel (name = "联系人(报价单才有)")
        private String contracts;

        /** 电话(报价单才有) */
        @ApiModelProperty ("电话(报价单才有)")
        @TableField ("phone")
        @Excel (name = "电话(报价单才有)")
        private String phone;

        /** 邮箱(报价单才有) */
        @ApiModelProperty ("邮箱(报价单才有)")
        @TableField ("email")
        @Excel (name = "邮箱(报价单才有)")
        private String email;

        /** 是否内部单据(报价单才有) */
        @ApiModelProperty ("是否内部单据(报价单才有)")
        @TableField ("is_internal")
        @Excel (name = "是否内部单据(报价单才有)")
        private Boolean isInternal;

        /** 结算币别（结算币别接口） */
        @TableField ("settlement_currency")
        @ApiModelProperty ("结算币别（结算币别接口）")
        private String settlementCurrency;

        @TableField(exist = false)
        @ApiModelProperty("结算币别名称")
        private String settlementCurrencyName;

        /** 本位币 */
        @ApiModelProperty ("本位币")
        @TableField ("base_currency")
        @Excel (name = "本位币")
        private String baseCurrency;

        /** 汇率类型（汇率类型接口） */
        @TableField ("exchange_rate_type")
        @ApiModelProperty ("汇率类型（汇率类型接口）")
        private String exchangeRateType;

        /** 汇率 */
        @ApiModelProperty ("汇率")
        @TableField ("exchange_rate")
        @Excel (name = "汇率")
        private String exchangeRate;

        /** 付款条件（付款条件接口） */
        @TableField ("pay_condition")
        @ApiModelProperty ("付款条件（付款条件接口）")
        private String payCondition;

        /** 结算方式（结算方式接口） */
        @TableField ("settlement_method")
        @ApiModelProperty ("结算方式（结算方式接口）")
        @Excel (name = "结算方式", readConverterExp = "结=算方式接口")
        private String settlementMethod;

        /** 价格类型 */
        @ApiModelProperty ("价格类型")
        @TableField ("price_type")
        @Excel (name = "价格类型")
        private String priceType;

        /** 是否含税 */
        @ApiModelProperty ("是否含税")
        @TableField ("is_tax")
        @Excel (name = "是否含税")
        private Boolean isTax;

        /** 询价单名称 */
        @ApiModelProperty ("询价单名称")
        @TableField ("inquiry_name")
        @Excel (name = "询价单名称")
         private String inquiryName;

        /** 是否含价外税 */
        @ApiModelProperty ("是否含价外税")
        @TableField ("is_extra_price_tax")
        @Excel (name = "是否含价外税")
        private Boolean isExtraPriceTax;

        /** 审核人 */
        @ApiModelProperty ("审核人")
        @TableField ("examine_by")
        @Excel (name = "审核人")
        private String examineBy;

        /** 审核日期 */
        @ApiModelProperty ("审核日期")
        @TableField ("examine_time")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "审核日期", width = 30, dateFormat = "yyyy-MM-dd")
        private Date examineTime;

        /** 确认状态 */
        @ApiModelProperty ("确认状态")
        @TableField ("confirm_status")
        @Excel (name = "确认状态")
        private String confirmStatus;

        /** 确认人 */
        @ApiModelProperty ("确认人")
        @TableField ("confirm_by")
        @Excel (name = "确认人")
        private String confirmBy;

        /** 关闭人 */
        @ApiModelProperty ("关闭人")
        @TableField ("close_by")
        @Excel (name = "关闭人")
        private String closeBy;

        /** 关闭日期 */
        @ApiModelProperty ("关闭日期")
        @TableField ("close_time")
        @JsonFormat (pattern = "yyyy-MM-dd")
        @Excel (name = "关闭日期", width = 30, dateFormat = "yyyy-MM-dd")
        private Date closeTime;

        /** 关闭状态 */
        @ApiModelProperty ("关闭状态")
        @TableField ("close_status")
        @Excel (name = "关闭状态")
        private String closeStatus;

        /** 是否发送第三方消息通知 */
        @ApiModelProperty ("是否发送第三方消息通知")
        @TableField ("third_message")
        @Excel (name = "是否发送第三方消息通知")
        private Boolean thirdMessage;

        /** 第三方消息模板 */
        @ApiModelProperty ("第三方消息模板")
        @TableField ("third_template")
        @Excel (name = "第三方消息模板")
        private String thirdTemplate;

        /** 逻辑删除 */
        @ApiModelProperty ("逻辑删除")
        @TableField ("is_used")
        @Excel (name = "逻辑删除")
        private Integer isUsed;

        @ApiModelProperty ("创建人")
        @TableField ("create_by")
        @Excel (name = "创建人")
        private String createBy;

        @ApiModelProperty ("创建时间")
        @TableField ("create_time")
        @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss" )
        @Excel (name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
        private Date createTime;

        @ApiModelProperty ("修改人")
        @TableField ("update_by")
        @Excel (name = "修改人")
        private String updateBy;

        @ApiModelProperty ("修改日期")
        @TableField ("update_time")
        @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss" )
        @Excel (name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
        private Date updateTime;

        @ApiModelProperty ("备注")
        @TableField ("remark")
        @Excel (name = "备注")
        private String remark;

        @ApiModelProperty ("流程实例id")
        @TableField ("instance_id")
        private String instanceId;

        @ApiModelProperty ("流程状态")
        @TableField ("state")
        private String state;

        @ApiModelProperty("业务type")
        @TableField (exist = false)
        private String businessType;

        @ApiModelProperty("流程模型id")
        @TableField (exist = false)
        private String modelId;

        @ApiModelProperty("适用供应商信息")
        @TableField(exist = false)
        private List<KingInquirySupplierEntity> inquirySupplierList;

        @ApiModelProperty("报价采纳信息")
        @TableField(exist = false)
        private List<KingInquiryQuotationEntity> inquiryQuotationList;

        @ApiModelProperty("明细信息")
        @TableField(exist = false)
        private List<KingInquiryDetailEntity> inquiryDetailList;


}
